package com.qingcloud.adminbackend.entity.sysorder;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;
import java.util.Set;

/**
 * <p>
 * 订单表
 * </p>
 *
 * @author liyuhong
 * @since 2018-12-20
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("sys_order")
public class SysOrder extends Model {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "id", example = "")
    private String id;
    /**
     * 订单名称
     */
    @ApiModelProperty(value = "订单名称", example = "")
    private String orderName;

    /**
     * 订单类型（1:销售合同，2：样机，3：测试项目）
     */
    @ApiModelProperty(value = "订单类型（1:销售合同，2：样机，3：测试项目）", example = "")
    private Integer orderType;

    /**
     * 服务类型(1:设备和服务，2：设备，3：服务)
     */
    @ApiModelProperty(value = "服务类型(1:设备和服务，2：设备，3：服务)", example = "")
    private Integer serviceType;

    /**
     * 订单服务周期 开始时间
     */
    @ApiModelProperty(value = "订单服务周期 开始时间", example = "")
    private String startTime;

    /**
     * 订单服务周期 结束时间
     */
    @ApiModelProperty(value = "订单服务周期 结束时间", example = "")
    private String endTime;

    /**
     * 业务类型（1：网格化，2:健康云）
     */
    @ApiModelProperty(value = "业务类型（1：网格化，2:健康云）", example = "")
    private Integer businessType;

    @TableField(exist = false)
    @ApiModelProperty(value = "业务类型名称", example = "")
    private String businessTypeName;

    /**
     * 客户ID
     */
    @ApiModelProperty(value = "客户ID", example = "")
    private String orgId;

    /**
     * 描述
     */
    @ApiModelProperty(value = "描述", example = "")
    @TableField(value = "`describe`")
    private String describe;
    /**
     * 合同id
     */
    @ApiModelProperty(value = "合同id", example = "")
    private String contractId;

    @ApiModelProperty(value = "0:未删除 1:已删除", example = "0")
    private Integer deleteFlag;

    /**
     * 合同管理编号
     */
    @ApiModelProperty(value = "合同管理编号", example = "")
    @TableField(exist = false)
    private String contractCode;

    /**
     * 合同名称
     */
    @ApiModelProperty(value = "合同名称", example = "")
    @TableField(exist = false)
    private String contractName;

    /**
     * 签署人员
     */
    @ApiModelProperty(value = "签署人员", example = "")
    @TableField(exist = false)
    private String signBy;

    /**
     * 签署日期
     */
    @ApiModelProperty(value = "签署日期", example = "")
    @TableField(exist = false)
    private LocalDateTime signTime;


    /**
     * 客户联系人
     */
    @ApiModelProperty(value = "客户联系人", example = "")
    @TableField(exist = false)
    private String orgBy;

    /**
     * 客户电话
     */
    @ApiModelProperty(value = "客户电话", example = "")
    @TableField(exist = false)
    private String orgPhone;

    /**
     * 客户邮箱
     */
    @ApiModelProperty(value = "客户邮箱", example = "")
    @TableField(exist = false)
    private String orgMailbox;

    private LocalDateTime createDt;

    private String createBy;

    private LocalDateTime modifyDt;

    private String modifyBy;

    /**
     * 客户名称
     */
    @ApiModelProperty(value = "客户名称", example = "")
    @TableField(exist = false)
    private String orgName;

    @ApiModelProperty(value = "功能Ids")
    @TableField(exist = false)
    private Set<String> functionIds;

    @ApiModelProperty(value = "模块集合Ids")
    @TableField(exist = false)
    private Set<String> moduleIds;

    @ApiModelProperty(value = "设备数量")
    @TableField(exist = false)
    private int equipmentNumber;

    @ApiModelProperty(value = "是否可管理")
    @TableField(value = "`manage`", exist = false)
    private int manage;

    @ApiModelProperty(value = "是否可读")
    @TableField(value = "`read`", exist = false)
    private int read;

    @ApiModelProperty(value = "订单数")
    @TableField(exist = false)
    private int ordernum;
}
